import React from 'react';
import { NavBar, Space, Toast } from 'antd-mobile';
import { UserOutline } from 'antd-mobile-icons';
import { useHistory } from "react-router-dom";


export default () =>{
    const history = useHistory();

    const Go = (e)=>{
        e.stopPropagation();
        history.push('/mine');
    }

    const right = (
        <div style={{ fontSize: 18 }}>
            <Space>
                <UserOutline onClick={ Go }/>
            </Space>
        </div>
    )

    const back = () => {
        history.go(-1);
    }

    return (
        <NavBar right={right} onBack={back}>
            蓝点网
        </NavBar>
    )
}